Orientation sensing system and method for a spherical body

ABSTRACT

A spherical motor (10) provides smooth isotropic motion. The spherical motor (10) has a spherical stator (12) surrounding a spherical rotor (18). A motor shaft (24) is mounted to the rotor (18), or alternatively, to the stator (12) for performing work in isotropic motion. A grid pattern is situated to move substantially concentrically with the rotor (18) and in conjunction with the motor shaft (24). A vision system (80) monitors the grid pattern (42) and determines in real time the position of the motor shaft (24). The vision system (80) has at least one image sensor (44) positioned on the stator (12) and a computer system (82) for processing data independent of a remote host computer (122). Further, a motor controller (191) using a motor control algorithm (200) may be interfaced with the vision system (80) to thereby derive a motor control system (190) for controlling the spherical motor (10) based upon the rotor orientation information retrieved by the vision system (80). Finally, a video controller (106) can be interfaced with the vision system (80) for converting digital image data in real time to analog image data conforming to the RS-170 television standard for viewing on a display device (116).

The U.S. Government has a paid-up license in this invention and the right in limited circumstances to require the patent owner to license others on reasonable terms as provided for by the terms of contract number E-25-644 awarded by the National Science Foundation.

FIELD OF THE INVENTION

The present invention generally relates to tracking and monitoring rotational bodies, for example but not limited to, a spherical rotor within a spherical motor.

PRIOR ART

An increasing need for high performance robotic applications has motivated researchers to investigate new actuator concepts for improving the dexterity of robotic wrists. Examination of existing mechanical joints reveals that the ball-joint-like spherical actuator is an attractive alternative to the three consecutive rotational joint configuration. The interest in spherical motors in a robotic wrist is triggered because of its simple design, its ability in providing the roll, yaw, and pitch motion in a single joint, and its isotropic kinematics and kinetics. Also, it has no singularity in the middle of work space except the boundary. In other words, it provides for movement in any direction at any given instant in time. Further, the elimination of gears and linkages enables both high precision positioning and fast dynamic response. The foregoing attractive features make spherical motors attractive for use with, for example, high speed plasma and laser cutting where the cutter orientation must be achieved rapidly and continuously in all directions. Other applications include coordinate measuring machines and tally operated joysticks, where continuous isotropic motion in all directions is necessary.

Recently, several design concepts for spherical motors were proposed by researchers in the art. A spherical induction motor for robotic applications was described in the following related publications: G. J. Vachtsevanos et al., "Development of a Novel Intelligent Robotic Manipulator," IEEE Control Systems Magazine, June 1987, K. Devey and G. J. Vachtsevanos, "The Analysis of Fields and Torques in a Spherical Induction Motor," IEEE Trans. Magnetics, vol. mag-23, March 1987, and U.S. Pat. No. 4,739,241 to G. J. Vachtsevanos et al. However, it is difficult to realize a prototype of this kind because of its complexity in mechanical and winding design and manufacturing, which requires inlaying all three transversing windings on the inner spherical surface of the stator. Laminations are required to prevent movement of unwanted eddy currents. Complicated three phase windings must be mounted in recessed grooves in addition to the rolling supports for the rotor in a static configuration. These and other configurations have led other researchers to investigate an alternative spherical motor based upon the concept of variable reluctance stepper motors, which are easier to manufacture.

In R. L. Hollis et al., "A Six Degrees of Freedom Magnetically Levitated Variable Compliance Fine Motion Wrist," Proceedings of the Fourth International Symposium on Robotics Research, Santa Cruz, August, 1987, a direct current (DC) "magic wrist" having six degrees-of-freedom (DOF) in rotation was disclosed as part of a robotic manipulator. A DC spherical motor with three DOF was described in K. Kaneko et al., "A Spherical DC Servo Motor With Three Degrees of Freedom," ASME Trans. On Dynamic Systems, Measurement and Control, vol. III, November 3, September, 1989, pp. 398-402, which can spin continuously and has a maximum inclination of 15°. Although the control of a DC spherical motor is relatively simple, the range of inclination and the torque constant are rather limited. Furthermore, an induction type spherical motor of different structure, which has a range of motion characterized by a cone of 60°, was disclosed in A. Foggia et al., "New Three Degree of Freedom Electromagnetic Actuator," Conference Record--IAS Annual Meeting, vol. 35, no. 6, published by IEEE, New York, N.Y., U.S.A., 1988, pp. 137-141.

As compared with its DC counterpart, a VR spherical motor has a relatively large range of motion, possesses isotropic properties in motion, and is relatively simple and compact in design. However, a VR spherical motor requires a very sophisticated control scheme. A dynamic model and control strategy for a VR spherical motor is discussed in K.-M. Lee, "Development of a Variable Reluctance Spherical Motor," Reprint of Proceeding of the 18th NSF Grantees Conference on Design and Manufacturing Systems Research, Atlanta, Ga., Jan. 8-12, 1992, the disclosure of which is incorporated herein by reference.

Furthermore, in order to control a VR spherical motor, a very sophisticated position encoding system is needed for monitoring the rotor orientation. If single access encoders are employed for measuring three DOF orientation of the ball-joint-like rotor, then a moving mechanism is generally required in order to constrain rotor motion to an extent so that roll, yaw, and pitch motion can be measured individually via single access shaft encoders. An example of a moving mechanism for a ball-joint-like joystick device which could be employed in a spherical motor is disclosed in Soviet Union Patent 1516344A. However, such a moving mechanism undesirably introduces friction, stiction, and inertia making the monitoring system impractical for many applications.

Hence, because of the requisite complex control and position encoding schemes, researchers have been unable to develop and implement a workable and practical VR spherical motor which can be used for the many desired applications described above.

SUMMARY OF THE INVENTION

Accordingly, an object of the present invention is to overcome the problems and deficiencies associated with the prior art.

Another object of the present invention is to provide a workable and practical VR spherical motor and associated methodology.

Another object of the present invention is to provide a spherical motor which is simple in structure, inexpensive to manufacture, and reliable in operation.

Another object of the present invention is to provide a spherical motor and method for allowing smooth isotropic orientation actuation and high positioning resolution.

Another object of the present invention is to provide a spherical motor and method for providing a large torque-to-weight ratio.

Another object of the present invention is to provide an orientation sensing system and method for measuring three DOF orientation of any spherical body, for example, a ball-joint-like device in a spherical motor, a robotic wrist, or a joystick.

Another object of the present invention is to provide an orientation sensing system and method for a spherical body for providing essentially non-contact measuring of position, thereby eliminating friction and stiction, minimizing the inertia of the measuring mechanism, and allowing for smooth isotropic joint motion.

Another object of the present invention is to provide a orientation sensing system for a spherical body which exhibits relatively simple kinematics and compact design.

Briefly stated, the present invention provides a spherical motor for providing smooth isotropic motion, an orientation sensing system for permitting non-contact orientation measurement of a spherical body, for example, the spherical rotor of the novel spherical motor, a vision system for permitting real time processing of an image, for instance, an image from an image sensor of the novel orientation sensing system, and a motor control system for interfacing with the vision system and controlling the spherical motor with the aid of a motor control algorithm.

The spherical motor has a spherical stator with a plurality of stator pulls. A spherical rotor is surrounded by the stator and has a plurality of rotor pulls. A shaft mounted to the rotor protrudes through a stator opening for permitting isotropic movement of the shaft. A grid pattern is situated substantially concentric with the rotor and is movable in conjunction therewith. In a preferred embodiment, the grid pattern is situated on the outside of the rotor itself. An image sensor is disposed on the stator for viewing the grid pattern. A processor associated with the image sensor determines the position of the shaft via the image of the grid pattern sensed by the image sensor.

The orientation sensing system, which has been implemented in association with the spherical motor, permits non-contact position measurement of any spherical body, including but not limited to, the rotor of the novel spherical motor. Broadly conceptualized, the orientation sensing system includes the following elements. It includes a grid pattern situated substantially concentric with the spherical body and movable in conjunction therewith. An image sensor is disposed to view the grid pattern. Finally, a processor is associated with the image sensor for determining the position of the spherical body based upon an image of a portion of the grid pattern which is retrieved by the image sensor.

The vision system, which has been implemented in association with the spherical motor, permits real time processing of images, including but not limited to, those images retrieved by the orientation sensing system of the novel spherical motor. The vision system is described as follows. A computer system has a digital signal processor for processing digital image data, a communications port (serial or parallel) for communicating with a host computer, a ROM for receiving a program for operating the computer system from the host computer, and a RAM for receiving and running the program. An imaging system is in communication with the computer system. The imaging system has an image sensor for receiving an image from an illuminated object, for example but not limited to, the novel grid pattern on a spherical motor rotor, an analog-to-digital converter for converting the image to digital image data, and a video buffer for storing the digital image data. Finally and significantly, the vision system has a means for selectively causing the imaging system to discard pixel areas of the image which are outside of a pertinent pixel area containing the object, the pixel area being defined by selectable rows and selectable columns, and for directly transferring the pertinent pixel area to the digital signal processor. In addition, the vision system may also have a means for converting the area to an RS-170 standard signal for calibrating, storing, or direct viewing on any display device.

The motor control system interfaces with the vision system and controls the spherical motor with the aid of a motor control algorithm. The motor control system comprises a processor interfaced with the processor of the vision system and disposed for performing the motor control algorithm, a decoder communicating with the processor, and a DAC means for converting digital signals from the decoder into analog signals for each of the plurality of stator poles.

The motor control algorithm optimally controls the spherical motor by determining stator current values U_(i) for i=1, . . . ,n for n stator poles in order to achieve desired torques. The algorithm involves minimizing total energy input to the stator poles when determining the stator current values. Moreover, each stator current value U_(i) is compared to a maximum current value U_(max) and is replaced with the maximum current value if the stator current value exceeds the maximum current value, or when U_(i) >U_(max). Finally, the stator current values are forwarded to the n stator poles for ultimate control of the rotor.

Other objects, features, and advantages of the present invention will become apparent to one of skill in the art upon review of the following drawings and the detailed description of the preferred embodiments.

BRIEF DESCRIPTION OF THE DRAWINGS

The present invention, as defined in the claims, can be better understood with reference to the following drawings. The drawings are not necessarily to scale, emphasis instead being placed upon clearly illustrating principles of the present invention.

FIG. 1A is a cut-away perspective view of a spherical motor in accordance with the present invention;

FIG. 1B is an assembly view of the spherical motor of FIG. 1A having a plurality of ball bearing mechanisms for supporting a spherical rotor within a spherical stator;

FIG. 1C is a schematic view of the spherical motor of FIG. 1A having a plurality of fluid bearing mechanisms for supporting a spherical rotor within a spherical stator with a fluid, for example, air;

FIG. 1D is a schematic view of a fluid control valve for the fluid bearing mechanisms of FIG. 1C;

FIG. 1E is a block diagram of a closed loop control system for the fluid bearing mechanisms of FIG. 1C;

FIG. 2A is a graphical diagram of a spherical grid pattern for an orientation sensing system in accordance with the present invention;

FIG. 2B is an enlarged graphical view of a grid pattern image from an image sensor disposed to view the grid pattern of FIG. 2A;

FIG. 2C is a graphical diagram showing a grid pattern image at time t;

FIG. 2D is a schematic diagram showing the grid pattern image at time t+Δt;

FIG. 2E is a graph showing feasible regions of projected point P on the HV-plane of FIGS. 2B through 2D;

FIG. 2F is a flowchart illustrating the tracking of a grid pattern element on the grid pattern of FIG. 2A;

FIG. 3 is a block diagram illustrating a vision system for permitting real time processing and display of images, for instance, grid pattern images, in accordance with the present invention;

FIG. 4 is a block diagram of an imaging system of FIG. 3;

FIG. 5 is a block diagram of a real time video controller of FIG. 3;

FIG. 6 is a block diagram of a motor control system for interfacing with the vision system of FIG. 3 for the purpose of controlling the spherical motor of FIG. 1A in real time;

FIG. 7 is a flowchart illustrating a loader algorithm for downloading an image processing program from a host computer to the vision system of FIG. 3;

FIG. 8 is a flowchart illustrating operation of an image processing algorithm by the vision system of FIG. 3;

FIG. 9 is a schematic diagram of an approximate area A of an image which is retrieved in accordance with the image processing algorithm of FIG. 8; and

FIG. 10 is a flowchart illustrating an optimization algorithm for the motor controller of FIG. 6.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS 1. SPHERICAL MOTOR

With reference now to the figures wherein like reference numerals designate corresponding parts throughout the several views, FIG. 1A shows a ball-joint-like variable reluctance (VR) spherical motor 10 which permits isotropic motion, including roll, yaw, and pitch, in a single joint. The spherical motor 10 has potential applications in almost any ball-joint-like device where continuous isotropic motion in all directions is required. It can be used as a provider of force for performing work, for example, as a robotic wrist actuator. It also has potential applications as a receiver of force for monitoring motion, for example, as a coordinate measuring machine or as a joystick.

The spherical motor 10 comprises a spherical stator 12 having a plurality of internal bearing mechanisms (as examples, ball bearing type, FIG. 1B; or fluid type, FIGS. 1C-1E) and a plurality of poles 14 (FIG. 1B), each having preferably a controllable electric coil which can be individually energized and an associated core of suitable material, for example, a ferromagnetic (iron) material. The spherical stator 12 is supported by a support mechanism 16. A spherical rotor 18 is freely movable within the stator 12 as a result of the bearing mechanisms. The spherical rotor 18 has a plurality of rotor poles 22 (FIG. 1B), each preferably a ferromagnetic (iron) material core, a magnetic core, an electromagnet, or other suitable magnetic field generator. The spherical rotor 18 is concentric with the stator 12 and has an infinite number of rotational axes about its center with three degrees of freedom. A motor shaft 24 mounted to the rotor 18 at its base end 24a protrudes outwardly through a circular stator opening 26, which permits isotropic movement of a distal end 24b of the motor shaft 24. A hemispherical cover shell 28 has a central aperture 32 for receiving the motor shaft 24 therethrough. Essentially, the hemispherical cover shell 28 encloses the internal rotor 18 for added durability and may be provided with a grid pattern of an orientation sensing system, as will be described in detail relative to FIG. 2A.

Worth noting is that the spherical motor 10 of FIG. 1A may be configured so that the internal rotor 18 remains fixed while the surrounding stator 12 rotates isotopically about the rotor 18. In this case, the shaft 24 is mounted to the stator 12 for performing isotropic rotational work.

The bearing mechanisms are preferably realized in either a ball bearing configuration or a fluid configuration, as will now be described relative to FIGS. 1B and 1C-1E, respectively. However, obviously, other configurations are possible. FIG. 1B shows the spherical motor 10 having a plurality of ball bearing mechanisms 13 mounted in the stator 12 for supporting and permitting rotation of the rotor 18 therein.

Although not necessary, it is advisable to space the ball bearing mechanisms 13, the stator poles 14, and the rotor poles 22 at the vertices of regular polyhedron configurations modelled about the spherical motor 10 for achieving optimum torque and optimum forced rotational motion. Placement of rotor and stator poles of a spherical motor in polyhedron configurations is described in K.-M. Lee, "Development of a Variable Reluctance Spherical Motor," Reprint of Proceeding of the 18th NSF Grantees Conference on Design and Manufacturing Systems Research, Atlanta, Ga., Jan. 8-12, 1992. However, other spacing configurations are possible. In addition, the rotor 18 should be provided with less poles than the stator 12 so as to avoid electromechanical singularity, which would result in the loss of one or more degrees of freedom (DOF). Furthermore, for proper rotor stability, at least four ball bearing mechanisms 13 should be employed. The four bearing mechanisms are located on the stator 12 such that one of the bearing mechanisms 13 is mounted perpendicular to a plane formed by the other three bearing mechanisms 13. For practical reasons, however, a greater number than four is preferred because in this case the load is shared among the various ball bearing mechanisms 13, thus enabling the use of smaller, inexpensive ball bearing mechanisms and thus enhancing ball bearing longevity.

FIG. 1C shows the spherical motor 10 having a plurality of fluid bearing mechanisms 33 mounted in the stator 12 for supporting and permitting rotation of the rotor 18 therein. At least three pairs (the mechanisms 33 of each pair being mounted diametrically opposed as shown in FIG. 1C) of orthogonal fluid bearing mechanisms 33 are needed in order to provide at least three pairs of opposing normal forces acting radially towards the center of the rotor 18. Preferably, five pairs of fluid bearing mechanisms 33 are utilized to support the rotor 18. The five pairs are evenly spaced on two circular rings which are parallel and symmetrical about the YZ plane of FIG. 1A. Only a pair of fluid bearing mechanisms 33 are illustrated in FIG. 1C for simplicity.

Each fluid bearing mechanism 33 discharges a jet of fluid, such as a liquid or gas, at respective pressures P₁ and P₂. Preferably, the fluid is air and is projected via pneumatic means. The pair of radial forces acts diametrically through the center of the rotor 18 so that one of the radial forces acts on one rotor hemisphere and the other acts on the other rotor hemisphere. The fluid or air impinging upon the rotor 18 within the stator 12 is discharged through the stator opening 26.

The pressures P₁ and P₂ can be controlled by a fluid flow control valve 34, shown schematically in FIG. 1D. Fluid at constant pressure P_(S) is caused to flow through two paths 35a, 35b, each comprising a constant restriction R in series with a variable restriction R₁, R₂, respectively. The two constant restrictions R, R of the two paths 35a, 35b have equal resistance to the fluid flow at pressure P_(S). By varying the cross-sectional areas of the variable restrictions R₁, R₂, the pressures P1, P2 can be controlled by an external electromechanical input x.

Each of the fluid bearing mechanisms 33 has an associated closed loop control system 36, as shown in FIG. 1E, for control and monitoring the fluid flow against the rotor 18. The closed loop control system 36 achieves a constant spacing between the stator 12 and the rotor 18 by means of a high resolution optical sensor 37, preferably a Hewlett Packard HPHBCS-1100 sensor. The external electromechanical input x of FIG. 1D is controlled by a controller 38, for example, a torque motor in combination with a digital proportional-integral-derivative (PID) controller or some other suitable controller device. The controller 38 generates the input x based on the difference between a desired reference input δ_(P) and the actual spacing δ_(P) from the feedback optical sensor 37 having associated sensor signal processor 39. The sensor signal processing 39 is, for example, an analog amplification circuit with an analog-to-digital converter (ADC).

Furthermore, in addition to fluid suspension of the rotor 18 within the stator 12, it is envisioned that the rotor 18 may be suspended within the stator 12 via other mechanisms, such as electrostatic means.

2. ORIENTATION SENSING SYSTEM

An orientation sensing system 40 for permitting non-contact position and direction measurement of any spherical body, for example, the spherical rotor 18 of the spherical motor 10, is graphically illustrated in FIG. 2A. The orientation sensing system 40 provides for direction measurement of the combined roll, yaw, and pitch motion, eliminates friction and stiction, and exhibits a relatively low inertia.

In structure, the orientation sensing system 40 comprises a spherical grid pattern 42 situated on the exterior of the rotor 18 or on the interior of the hemispherical cover shell 28 and at least one image sensor Q_(1i) and preferably two image sensors Q_(1i), Q_(2i) spaced 90 degrees apart, as designated by respective reference numerals 44, 46 in FIG. 1A. The grid pattern 42 is made up of symmetrically spaced radial lines continuously converging at a point P, where the motor shaft 24 is situated, and a set of parallel lines which are orthogonal to the radial lines and which surround the point P. Essentially, the grid pattern 42 is similar to the longitude/latitude grid lines on an earth globe.

The orientation sensing system 40 of FIG. 2A is able to determine a body coordinate frame of the rotor 18 with respect to the surrounding stator 12. Use of the grid pattern 42 for determining the position of the motor shaft 24 is now described hereafter relative to FIGS. 2B through 2F. Worth noting is that the coordinate frames utilized in the following description are shown in FIGS. 1A and 2A. In this regard, a reference coordinate frame XYZ is situated at the center of the stator 12 with its X-axis pointing toward the opening of the spherical stator 12. A body coordinate frame uvw of the rotor 18 is defined at the center of the rotor 18 with its u-axis pointing along the motor shaft 24. The rotor coordinate frame uvw with respect to the stator coordinate frame XYZ is determined by computing the position of the motor shaft 24 and the spin about the motor shaft 24. In the following discussions, the following notations are used: A.sub.(·) denotes the angle measured from the X-axis to a position vector of a point (·) from the origin O. Similarly, α.sub.(·) denotes the angle measured from the positive u-axis to a position vector of the point (·). β.sub.(·) defines the angle measured from the positive v-axis to the projection of a position vector of the point (·) on the vw-plane. Both α.sub.(·) and β.sub.(·), are defined in the coordinate frame uvw.

2.1 Determination Of Motor Shaft Position

The position of the motor shaft 24 (or the u-axis) with respect to the XYZ frame of reference can be described by two of the three parameters; namely, Θ, Φ, and A as defined in FIGS. 1A and 2A. These three angles are constrained by the following orthogonal relationship:

    cos.sup.2 A+cos.sup.2 Φ+cos.sup.2 Θ=1            (1)

Two other independent geometrical equations are necessary in order to determine the three angles, Θ, Φ, and A.

The position vector OP which characterizes the motor shaft is given by

    OP=[R.sub.1 cosA R.sub.1 cosΦ R.sub.1 cosΘ].sup.T(2)

Consider any point e_(i) which lies on the intersection between the spherical surface of radius R₁ and the XY plane. The following relationship can be obtained from the vector dot product between Oe_(i) and OP:

    cosα.sub.ei =cosA.sub.ei cosA+sinA.sub.ei cosΦ   (3a)

    where

    OE.sub.i =[R.sub.1 cosA.sub.ei R.sub.1 sinA.sub.ei 0].sup.T.(3b)

Similarly, if e_(j) is a point on the intersecting line between the spherical surface of radius R₁ and the XZ plane. The dot product between a position vector Oe_(j) and OP:

    cosα.sub.ej =cosA.sub.ej cosA+sinA.sub.ej cosΘ.(4a)

    where

    Oe.sub.j =[R.sub.1 cosA.sub.ej O R.sub.1 sinA.sub.ej ].sup.T(4b)

Thus, if two or more points of the spherical grid surface can be measured such that their position vectors are known with respect to u- and X-axes, the angles Θ, Φ, and A can be determined from Equations (1) and (3) or (1) and (4).

2.2 Determination of Spin Angle

For a given shaft location, the spin is defined by the angle Φ measured from the right-half of the XY-plane to the v-axis on the vw-plane. As shown in FIG. 2A, the XY-plane intersects the vw-plane along the line Of₂ and thus, Φ is essentially the angle between the position vector Of₂ and the v-axis. Since the position vector Of₂ is perpendicular to OP, we have from their dot product, ##EQU1## Consider Q₁ to be a known point fixed on the XY plane such that

    OQ.sub.1 |.sub.xyz =[R.sub.1 cosA.sub.Q1 R.sub.1 sinA.sub.Q1 0].sup.T.                                                 (6)

The position vector OQ₁ can also be described with respect to the uvw frame as

    OQ.sub.1 |.sub.uvw =[R.sub.1 cosα.sub.Q1 R.sub.1 sinα.sub.Q1 cosβ.sub.Q1 R.sub.1 sinα.sub.Q1 sinβ.sub.Q1 ].sup.T                                  (7)

If the great circle passing through Q₁ and P intersects the vw-plane at f₃ as shown in FIG. 3, the spin angle can be determined by

    φ=β.sub.Q1 ±|Δφ|   (8)

where Δφ is the angle between the two position vectors, Of₂ and Of₃.

Let f₁ be an intersecting point between a great circle of radius R₁ passing through f₂ and P, and a circle described by the position vector OQ₁ as shown in FIG. 2. The angle Δθ can be determined from the dot product of the two vectors OQ₁ and Of₁ with respect to the uvw frame.

    cosΔθ=cos.sup.2 α.sub.Q1 +sin.sup.2 α.sub.Q1 cosΔφ                                           (9)

or with respect to the XYZ frame,

    cosΔθ=cosA.sub.Q1 (cosα.sub.Q1 cosA+sinα.sub.Q1 cosA.sub.f2)+sinA.sub.Q1 (cosα.sub.Q1 cosΦ+sinα.sub.Q1 sinA .sub.f2).                                            (10)

By equating Equations (9) and (10), Δφ can be found from Equation (11): ##EQU2## Thus, Equations (8) and (11) provide a means to determine the spin φ in terms of A, Φ, α_(Q), and β_(Q), where A_(f2) is given by Equation (5).

3. SENSOR KINEMATICS

In general, three independent parameters are necessary to uniquely define the orientation of rotor 18. As it has been shown in the previous subsections, the computation of the shaft location requires two position vectors to be known with respect to the X- and u-axes, A_(ei) and α_(ei) where i=1, 2. Once the motor shaft 24 is located, the spin about the u-axis can be characterized by an additional parameter β_(Q1) as shown in Equation (8).

Consider the spherical grid pattern 42 with a radius R₁. The spherical grid pattern 42 is concentric with the spherical rotor 18 and is preferably rigidly mounted on the motor shaft 24 (FIG. 1A). The grid pattern 42 comprises two sets of orthogonal lines which are denoted by constant α- and β- lines centered at the point P as shown in FIG. 2A. A constant α-line is essentially a circle centered at the u-axis such that the angle between a position vector of any point on the constant α-line and the u-axis is equal to α. The constant β-lines are a family of great circles with a common diameter which lies on the u-axis. The angle measured from the v-axis to a constant β-line on the vw-plane is equal to β. An array imaging sensor Q_(1i) is positioned so that a portion of the grid pattern at any instant can be registered. The optical axis of the imaging sensor 44 intersects the center of the spherical stator 12, and the spherical grid pattern 42 at Q₁. FIG. 3 shows the neighborhood of the optical center Q₁ in the object space. The coordinates of the grid points around Q₁ can be measured with respect to the local coordinate frame HV attached at the optical center Q₁.

In the following discussion, the notation ξ.sub.(·) is used to denote the angle between the position vectors of the point (·) and Q₁ : ##EQU3## where r_(obj) (·) defines the distance between the point (·) and the optical axis OQ₁.

3.1 Single Image Sensor

The determination of the motor shaft position requires two known position vectors with respect to X- and u-axes. Since the optical center Q₁ is known and is fixed on the XY-plane, the two intersecting points between the H-axes and the two adjacent α-lines can be characterized with respect to the X-axis:

    A.sub.ei =A.sub.Q1 -ξ.sub.ei i=1 and 2.                 (13)

By using Equation (4), the angles which characterize the motor shaft position can be determined from Equation (14): ##EQU4## Since the inclination of the motor shaft 24 is constrained by the spherical stator to ±90°, A is less than 90°.

The coordinates of Q₁ (α_(Q1), β_(Q1)) must be computed in order to determine the spin. By replacing the subscript "ei" to "Q1" in Equation (3) and substituting cosA and cosΦ from Equation (14) into the resulting equation, α_(Q1) can be determined from Equation (15): ##EQU5## where Δα is the angle between two adjacent α-lines. Alternatively α_(Q1) can be determined by using the intersecting points between the adjacent and α- and β-lines around Q₁, which are denoted by b₁ (i=1, 2, 3, 4) as shown in FIG. 2b. By noting that ##EQU6## Since β_(Q1) can be inferred from the image as follows:

    β.sub.Q1 =β.sub.b1 -Δβ.sub.1          (19)

the spin can be computed from Equations (8), (11), and (17)-(19).

3.2 Dual Imaging Sensors

Similarly, if a second image sensor 46 located at the Q_(2i) in XZ-plane, the coordinates of Q₂ and its adjacent grid points can be measured. Note that α_(Q1) and α_(Q2) can be rewritten from Equations (3) and (4) by replacing the subscripts "ei" to "Q1" and "ej" to "Q2" respectively:

    cosα.sub.Q1 =cosA.sub.Q1 cosA+sinA.sub.Q1 cosΦ   (20)

    cosα.sub.Q2 =cosA.sub.Q2 cosA+sinA.sub.Q2 cosΘ (21)

For a given design, the angle A, Φ, and Θ can be solved from the three simultaneous Equations (1), (20), and 21 in terms of the angles α_(Q1) and α_(Q2). For the case of A_(Q1) =A_(Q2), the position of the motor shaft can be determined by ##EQU7## There are two possible solutions in Equation (9). The locations of Q_(1i) and Q_(2i) are designed so that the correct solution can be determined by examining the feasible range of the center P for a given range of the shaft inclination.

As shown in FIG. 2A, the XZ-plane intersects the vw-plane along the line Of₅. Let f₆ be a point on the vw-plane at which a circle passing through Q₂ and P intersects. The spin angle can be computed from the second image sensor 46 as follows:

    φ=β.sub.Q2 +|β.sub.f25 |±|Δφ.sub.2 |     (25)

where β_(f25) and ΔΦ are the angles between Of₂ and Of₅, and Of₅ and Of₆, respectively. Using a similar approach as developed with a single image sensor 44, ##EQU8##

3.3 Moving Grid Pattern

For a given sensor design, the known parameters are Δα, Δβ, R₁, A_(Q1), and A_(Q2). The geometrical relationships derived in the previous sections 3.1 and 3.2 provide a means to determine the rotor orientation at a particular time instant t. The grid pattern 42, however, may move with respect to the optical center. If the optical center remains in the grid element in the new time step t+Δt, only the node distances r_(obj) (b₁) and r_(obj) (b₃) are required to be recomputed. In general, these variables must be recalculated if the optical center is out of the original grid element bounded by the four nodes. In order to update the variables for a new time step t+Δt, a method has been devised to locate the four "new" nodes around the image center.

FIGS. 2C and 2D show two consecutive images at the time t and t+Δt respectively. These images are shown in the memory coordinate frame H_(m) V_(m), where Q_(1m) denotes the corresponding image center. The method is based on examining whether the β_(b1) line (connecting the nodes b₁ to b₃) crosses the positive or the negative sides of the coordinate frame HV. At the time step t+Δt, the grid pattern 42 may move so that the image center may appear in one of the eight neighboring elements g₁ -g₈ or remain in its original element. Consider that the image center at t+Δt is in the grid element g₄ as shown in FIG. 2D, where the dotted circle centered at the original node represent a bounded region in which the node may displace within the time interval Δt. The radius of the bounded region, as denoted by r_(m), in FIG. 2D depends on the maximum displacement and velocity for a given sensor design. At t+Δt, the image processing algorithm searches for a node within the bounded circular regions, and compute for the variables Δβ₁ and α_(Q1) which are defined in FIG. 2B. If Q_(1m) is in one of the grid elements g₃, g₄, and g₅, the value of Δβ₁ will be greater than that of Δβ. Similarly, based on the definition of α_(Q1), the grid element which contains the image center Q_(1m) can be inferred by comparing the value of α_(Q1) against those of α_(b1) and α_(b3). These results are summarized in FIG. 2D.

In order to make a distinction between grid elements (g₁, g₈, g₇) from that (g₂, g₆), the projection of the center P on the HV-plane is divided into three regions as shown in FIG. 2E. The three regions denoted as I, II, and III are regions on which the projection of the center P could possibly lie on the HV-plane. Note that the v-axis is in the XY-plane. If Q_(1m) remains in the original grid element, g₂ or g₆, the intersection between the β_(b1) -line and the H_(m) and V_(m) axes must satisfy the following conditions: (1) The β_(b1) -line intersects the positive V_(m) axis and negative H_(m) axis if the projection of P is in the right half of the positive HV plane. (2) The β_(b1) -line intersects the negative V_(m) axis and negative H_(m) axis if the projection of P is in the left half of the positive HV plane. An algorithm to determine the grid element is summarized in FIG. 2F.

The allowable velocity of the orientation sensor 40 increases with a larger grid spacing for a given area and a short incremental time for the image processing and computation. On the other hand, the resolution is improved with a decrease in grid spacing, for the same surface area. By preferably using two image sensors, 44, 46, and two different kinds of grid lines, the allowable speed of the system can be increased without losing resolution. Different kinds of grid lines could include, for example, alternate coarse and fine grid lines, alternate light and dark grid lines, successive grid lines of different colors, or any other kind of grid line encoding methodology.

Worth mentioning is that, in order to further enhance rotor position computations, the rate of the relative movement between the rotor 18 and stator 12 may be further monitored by sensing the current induced in a secondary coil wound of one or more stator poles 14 under the influence of the magnetic field established between the stator poles 14 and the rotor poles 22. As is known by those skilled in the art, the mathematical integration of a rate yields position.

4. VISION SYSTEM

Although significant research efforts have been directed towards the use of machine vision for tracking objects, the capabilities of commercial vision systems for use in real time control systems are still very limited. Many vision systems today normally employ a camera that outputs a video signal limited by the traditional television set, such as the RS-170 standard established in the 1950s, and must be accompanied by a frame grabber and a high performance host computer. In regard to the RS-170 standard, see EIA Standard, "Electrical Performance Standards--Monochrome Television Studio Facilities," Electronic Industries Association, Engineering Department, November 1957. Once the image has been digitized by the frame grabber, the image must then be transferred from the frame grabber over the data bus of the host computer to a processing unit. The data bus of microcomputers has generally restricted the throughput of image processing. High performance, RISC-based, digital signal processors (DSP) are increasingly being used as an add-on board to the host computer. DSPs permit high powered, mathematically intensive algorithms to manipulate and enhance images. Although many frame grabbers and DSPs operate at a rate typically faster than that of the host bus, the frame grabber and DSP must continually wait on data from the host computer. This wait represents crucial overhead in a real time environment.

To eliminate pixel data transfer via the data bus, many frame grabbers contain an on-board image memory (or, a video buffer), a digital-to-analog converter (DAC) to display images at 30 frames per second (fps), and an external connection to allow direct data transfer and communication between the frame grabber and the add-on DSP. Hence, the conventional vision approach generally requires a substantial amount of memory, data communication time, and sophisticated vision interpretation.

U.S. Pat. No. 5,146,340 to Dickerson et al. a vision system for reading and processing pixel data. However, the Dickerson et al. system is limited in that only one image sensor can be used to provide real time response. As mentioned, in the preferred embodiment of the present invention, two image sensors 44, 46 is desirable.

In order to overcome the limitations and problems associated with conventional vision systems for use with real time control of the ball-joint-like spherical motor 10, a real time vision system 80 has been developed and is illustrated in FIG. 3. The vision system 80 offers high performance and cost advantages by integrating processing elements and the image sensors 44, 46, thereby eliminating the need for the host computer, a frame grabber, and a dedicated computational processing system. The vision system 80 further minimizes image processing time and increases the frame rate. By directly controlling the image sensors 44, 46, frame rates much higher than 30 fps can be achieved.

Generally, the vision system 80 comprises (a) a computer system 82 having a DSP 84, and an EEPROM 86, and a scratch RAM 88, and a communications interface 92, (b) an imaging system 94 having control logic 96, an image sensor 44 which is preferably a charge couple device (ccd), a flash analog-to-digital converter (ADC) 102, a video buffer 104 (also, video RAM, or VRAM), and a light source 105 for projecting light onto an object, such as the grid pattern 42, under the control of the control logic 96, and (c) a real time video controller 106 having a VRAM 108 and a video ADC 112 controlled by control logic 114 in order to provide an RS-170 standard video signal to any display device 116, such as a conventional monitor or video recorder.

As shown in FIG. 3, the computer system 82 may be interfaced with a robot controller 118 or a host computer 122. Via the host computer 122, calibration and/or image analysis can be performed and application specific software may be implemented. Furthermore, the computer system 82 provides a direct software control of image sensor scanning and integration time, control of the intensity of the collocated illumination, and control of the real time execution of a user selectable vision algorithm embedded in the EEPROM 86. In essence, all of the real time processing is performed in the computer system 82 independently of and without relying upon any other system or computer.

The DSP 84 is preferably a Motorola 56-bit digital signal processor DSP56001. However, many other suitable DSPs are commercially available, including but not limited to, the Motorola DSP96002, Texas Instruments TMS320, or AT&T DSP32.

In the DSP 84 of FIG. 3, a combined address and data bus is indicated by reference numeral 124. The address bus 126 is 16 bits and the data bus 128 is 24 bits. The internal accumulators are 56 bit. The DSP 56001 processor 84 has 64K words (24 bit) of program memory space and two separate 64K words of data memory within an on-board RAM 132. With two banks of 64K words of RAM, the digital signal processor 84 is well suited for stereo and 24 bit color sensing. The DSP 84 also has 24 I/O pins on the communications interface 92 which can be configured for various functions, for example, serial communications and/or parallel I/O.

The imaging systems 94 can communicate image information (pixels) directly to the computer system 82 without prior storage in the local video buffer 104, allowing for direct processing of data by the computer system 82, if desired. Moreover, any number of imaging systems 94 may be interfaced with the external system bus 134. Thus, data from any number of image sensors 44, 46 may be sensed and quickly analyzed by the vision system 80. As mentioned previously, the spherical motor needs only one image sensor 44, but preferably two image sensors 44, 46. Hence, in the preferred embodiment, the vision system 80 comprises two parallel imaging systems 94, one dedicated to each image sensor 44, 46.

FIG. 4 illustrates a block diagram of the imaging system 94. A decoder 136, preferably a Texas Instruments ED1810 programmable logic array (PLA), receives a peripheral select (P.SELECT) signal 137, a read/write signal 139, and an address signal 141 from the DSP 84 via the system bus 134. The imaging system 94 is uniquely identified by a specific peripheral select signal 137. The decoder 136 decodes control signals from the system bus 134 in order to control the image sensor 44, the ADC 102, and the video buffer 104.

Specifically, the decoder 136 sends control signals to the image sensor 44 to initiate row shifts and column shifts in response to commands from the DSP 84. Particular row shifts and column shifts enables retrieving only a specific relevant area A from an image, as will be further discussed in detail relative to FIG. 9. The decoder 136 also provides control signals to the ADC 102 for performing an analog-to-digital conversion synchronized with row shifts. Finally, the decoder 136 enables the video buffer 104 when the DSP 84 reads or writes data to the video buffer 104.

The image sensor 44 is preferably a Texas Instruments TC211 CCD. The TC211 CCD is a small area image sensor with 192×165 active pixels. The output of the TC211 CCD is conditioned by an internal high gain bandwidth amplification circuit 138 and then sampled by a flash ADC 102, for example, a Motorola MC10319 ADC capable of sampling at up to 25 megahertz. The digitized image is then stored in the video buffer 104.

It should be noted that when pixel data is stored or processed in the vision system 80, it is first immediately sent to the DSP 84 and not stored as yet. After reaching the DSP 84, if the pixel data is to be stored, then it is transferred from the DSP 84 to the video buffer 104 for storage. Further, if the pixel data is to be processed, then it is immediately processed by the DSP 84. The foregoing architecture and functionality is described in further detail relative to the image processing algorithm 220 hereinafter. Moreover, the architecture and functionality permits real time operation of the vision system 80 and constitutes a significant improvement over the vision system described in U.S. Pat. No. 5,146,340 to Dickerson et al., which requires pixel data to be stored in a video buffer before processing of pixel data can commence.

A block diagram of the video controller 106 is illustrated in FIG. 5. As shown in FIG. 5, control logic 114 comprises a decoder 142, a timing generator 154, a display address 156 counter, and an address multiplexer 58. The decoder 142 is preferably a Texas Instruments ED1810 PLA.

In operation, the decoder 142 receives a peripheral select (P.select) signal 144, a read/write signal 146, and an address signal 148 from the system bus 134. The video controller 106 is uniquely identified by a specific peripheral select signal 144. The decoder 142 provides a write enable 152 for triggering operations for writing image data in the VRAM 108. The write enable 152 is received by the timing generator 154. The timing generator 154 controls the VRAM 108, the video DAC 112, the display address counter 156, and the address multiplexer 158. In the foregoing regard, the timing generator 154 sends horizontal sync (HSYNC), blanking, and clock signals to the video DAC 112, as indicated by a reference arrow 162. The timing generator 154 sends read/write enable, row address select (RAS), and column address select (CAS) signal to the VRAM 108, as indicated by reference arrow 164. The timing generator 154 sends row/column address select and CPU/display address select signals to the address multiplexer 158, as indicated by a reference arrow 166. Further, the timing generator 154 communicates a clear counter signal 168 to the display address counter 156. As further shown, the timing generator 154 receives an EPROM address 172.

The display address counter 156 further communicates a display address output 174 to the address multiplexer 158. The address multiplexer 158 receives an image address written from the digital signal processor 84 on the line 176. Image data from the system bus 134 is communicated to the VRAM 108 as indicated by reference arrow 178. A coaxial cable 186 is shown for connecting any conventional display device 116 to the video DAC 112.

The RS-170 standard mandates a total of 420 scan lines for a complete frame, including the vertical blanking interval. An interlaced scheme is used in the RS-170 standard, wherein each frame is divided into two identical fields of 210 scan lines. In accordance with the present invention, only 45 of the 210 scan lines are used to display image characteristic data. Each scan line starts with a horizontal synchronization signal to synchronize the video source and the display device 116. During the synchronization period, the screen is blanked out and the electronic beam on the display device will move from the last displayed scan line to the beginning of the new scan line. At the end of each field, the scanning beam moves from the bottom of the screen to the top.

Once the DSP 84 signals the peripheral select 144 to select the video controller 106 for writing the image data, the image data is written into the VRAM 108 under the timing sequences triggered by the decoder 142. The addresses of the image data pixels are defined by the address multiplexer 158 under the control of the timing generator 154. If the peripheral select 144 is not enabled, the timing generator 154 continuously generates the required timing sequences to read the image data from the VRAM 108 and send the same to the video DAC 112. The video DAC 112 receives digital image data, synchronization signals, and blanking inputs from the timing generator 154 and converts them into the appropriate voltage levels according to the combination of these signals.

It should be noted that the decoders 136, 142 in the respective imaging system 94 and video controller 106 may be implemented as merely a combinational logic network, a state machine, or even a microprocessor, for example, a Motorola 86000 processor.

MOTOR CONTROL SYSTEM

A motor control system 190 for controlling the spherical motor 10 is illustrated in FIG. 6. The motor control system 190 has a motor controller 191 remotely interfaced with the vision system 80 by way of an external bus 192. Specifically, a DSP 84' of the motor controller 191 communicates with the DSP 84 of the remote vision system 80 via the external bus 192. The DSP 84 of the motor controller 191 communicates to a decoder 194 via a local bus 196. The decoder 194 controls a set of current signal generators 197 for each of the plurality of stator poles 14 (FIG. 1B). Each current signal generator comprises a DAC 198 connected to a subsequent current amplifier (AMP) 199.

A motor control algorithm 200, in software or in hardware or both, is disposed or downloaded to the DSP 84' of the motor controller 191 for controlling the operation of the motor controller 191 based upon the rotor position information retrieved by the vision system 80. A variety of motor control algorithms 200 may be employed. An example of a novel motor control algorithm 200 is described in detail hereinafter relative to FIG. 10.

6. OPERATION A. Loader Algorithm

A loader algorithm 203 for downloading any program from the host computer 122 to the vision system 80 and/or the motor controller 191 is illustrated in FIG. 7. The loader algorithm 203 is preferably implemented in software. The loader software program is stored in the EEPROM 86 shown in FIG. 3. Once the vision system 80 is turned on, the loader software program is copied into the program RAM 88 so that the EEPROM 86 can be programmed under the control of the loader program in the RAM 88.

Referring to FIG. 7, the loader algorithm 203 is initiated by a character sent from the host computer 122 to the vision system 80. The loader algorithm 203 has a "load" (L) sequence set forth in flowchart blocks 206-214 and a "go" (G) sequence set forth in flowchart blocks 216-218. Either of the foregoing sequences may be initiated by the host computer 122. During the load sequence, the loader algorithm 203 causes the host computer 122 to send the program to be transferred to the communications interface 92, through the bus 124, and finally to the program EEPROM 86 (92, 124, 86 in FIG. 3). Moreover, during the go sequence, as set forth in flowchart blocks 216, 218, the loader algorithm 203 writes the transferred program from the EEPROM 86 to the RAM 88. The RAM 88 is used for running the transferred program because a RAM is much faster than a ROM.

Worth noting is that a library of processing algorithms for optimizing performance may be maintained in the host computer 122 and downloaded to the program EEPROM 86 for particular processing tasks. Furthermore, once the algorithms and data are downloaded into the EEPROM 86, the vision system 80 can function as an intelligent sensing system and communicate directly with the robot controller 118 without the host computer 122.

B. Image Processing Algorithm

A novel image processing algorithm 220 for operating the imaging system 94 will now be described relative to FIG. 8, which has been broken down into successive views on respective FIGS. 8A and 8B. The image processing algorithm 220, which is capable of being transferred by the loader algorithm 203, is stored in the program EEPROM 86 of the computer system 82, and is run by the DSP 84 while in the program RAM 82. A significant aspect of the image processing algorithm 220, which is elaborated upon in detail hereinafter, is that partial frames (pertinent areas) of an image are captured instead of the customary full frame and the partial frames are directly sent to the DSP 84, thereby reducing the cycle time required to capture and process an image.

With reference to FIG. 8A, an image of the grid pattern 42 is acquired by the image sensor 44 by first initializing the image sensor 44 by an autoclear clearing process, as indicated in a flowchart block 224. Specifically, in response to a command from the DSP 84 (FIG. 3), the decoder 136 (FIG. 4) provides a control signal to the image sensor 44 for shifting out a row without storing the data, thereby "autoclearing", or in other words, not allowing a charge (image) to accumulate in the image sensor 44.

After the autoclear clearing process, an STRA command is asserted to the DSP 84 for setting a couple of time intervals used for subsequent timing operations and for sending a signal from the DSP 84 to the image sensor 44 to charge the strobe. A CNTI time interval is needed for charging the light strobe and for light integration, by the image sensor 44. Light integration refers to the concept of capturing light over time and hence capturing an image in the image sensor 44.

Next, as indicated in flowchart blocks 226, 228, while the image sensor 44 is illuminating the grid pattern 42, the DSP 84 computes the position, or coordinate, of the motor shaft 24 based upon previous grid pattern data stored in the video buffer 104 of the imaging system 94. The foregoing feature is a significant aspect of the present invention in that extremely high performance is achieved so as to realize real time operation. Computations by the DSP 84 occur concurrently with the retrieval of images by the imaging system 94.

As indicated in a subsequent flowchart block 232, it is determined whether the CNTI time interval needed for light integration has completed. Generally, the time for computing a coordinate of the motor shaft 24 takes less time than light integration.

After light integration has completed, an STRB command is asserted, as indicated in a flowchart block 234, causing the DSP 84 to send a signal to the imaging system 94 to discharge the stroke.

While the image is being acquired, the DSP 84 determines an approximate area where the object is located. The approximate area A is defined by row n to row m and column 1 to column p, as shown in FIG. 9. U.S. Pat. No. 5,146,340 to Dickerson et al., which is incorporated herein by reference, describes an image reading system wherein after ascertaining the area of an image where an object is located, the system is speeded up to read image signals outside the area at a high speed and to read those image signals inside the area at a slower speed. This invention can be applied herein so that the area A identified between rows m to n and columns j to k, as shown in FIG. 9, is read at a much higher speed than the remainder of the image. However, it should be noted that this implementation is optional and that the present invention is much more flexible in that a specific range of columns can be excised from the image, unlike in the foregoing patent where the excised portion always must start at column 1.

As indicated in a flowchart block 236 of FIG. 8A, the image processing algorithm 220 issues a row shift command to the DSP 84, thereby causing the decoder 136 to order the image sensor 44 to reel through rows 1 to n. As mentioned, the preceding process may be performed at a high speed, if desired, because the associated image region between rows 1 to n is unimportant. An RCNTB time interval is the amount of time needed to shift up to row n at high speed. As indicated in a flowchart block 238, the algorithm 220 waits until the row shift is complete by monitoring the RCNTB time interval.

Next, a memory pointer is set, as set forth in a flowchart block 242, so that only the area A beyond row n is saved in the video buffer 104.

Pixel data is now either stored or processed, as indicated at a flowchart block 244. Storage of pixel data occurs as set forth in flowchart blocks 246 through 256 and processing of pixel data occurs as set forth in flowchart blocks 258 through 268.

When pixel data is stored, an RCNT time interval is calculated and set for indicating the time necessary to shift out rows n through m. A row shift command is subsequently asserted, as indicated in a flowchart block 248, to read from, or shift out, rows n to m. Rows n to m may be shifted out at a relatively slow scanning speed, if desired, to insure image integrity.

A CCNT time interval is calculated and set for indicating the time necessary to shift out columns j to k. In turn, a column shift command is issued in order to shift out the area A between columns j to k. More specifically, as indicated in the flowchart block 249, the image processing algorithm 220 issues a column shift command to the DSP 84, thereby causing the DSP 84 to order the imaging system 94 to reel through columns 1 to j. As mentioned, the preceding process may be performed at a high speed, if desired, because the associated image region between columns 1 to j is unimportant. A CCNTB time interval is the amount of time needed to shift up to column j at high speed. As indicated in the flowchart block 251, the algorithm 220 waits until the column shift is complete by monitoring the CCTNTB time interval. Furthermore, the columns j to k may be shifted out at a relatively slow scanning speed, if desired, to insure image integrity.

After the entire area A has been shifted out row-by-row from row n to row m and with a row length spanning from column j to k, the autoclear clearing process is again initiated to end the image acquisition, as indicated by a flowchart block 272.

When pixel data is processed, the procedure is very similar to that for storing pixel data, as described above. Specifically, the flowchart blocks 258 through 268, setting forth the preferred procedure for processing pixel data, corresponds respectively with flowchart blocks 246 through 256, setting forth the preferred procedure for storing pixel data. However, at flowchart block 264, where columns are shifted out, the pixel data (for instance, 8 data bits) is processed and then directly stored.

Thus, with the image sensor 44 under control of the image processing algorithm 220, partial frames can be captured instead of the customary full frame, reducing the cycle time required to capture and process an image. The ability to shift out partial frames is ideal for high speed tracking applications where the approximate location is known from a prior image. By reducing the time to capture an image, the effective frame rate is increased. For example, shifting out one-fourth of an image can increase the frame rate up to 480 fps, not including the time required for illumination and image processing. This frame rate is 16 times the rate achievable from the RS-170 standard.

C. Motor Control Algorithm

FIG. 10 is a flowchart illustrating a novel motor control algorithm 200 for optimizing performance of the motor controller 191 of FIG. 6. The motor control algorithm 200 initially determines an actuating torque vector T=(T₁, T₂, T₃) (T₁, T₂, T₃ are orthogonal vector components) so that the spherical motor 10 follows a desired trajectory, as indicated in flowchart block 282. Many algorithms are available in the industry for the foregoing purpose. For example, consider a computed torque method for the control strategy as described in Spong et al., Robot Dynamics and Control, John Wiley and Sons, 1989, which is incorporated herein by reference as if set forth in full hereinbelow.

In the preferred embodiment, the actuating torque vector T is determined as described hereafter. The torque generated by the electromagnetic system of the spherical motor 10 is given by the following equation which is derived by using the principle of conservation of energy: ##EQU9## where M_(sj) and M_(ri) denote the magneto-motive-forces (mmf's) or the electrical inputs to the j^(th) stator pole 14 and the i^(th) rotor pole 22 respectively; V is the magnetic potential at the stator shell with respect to the rotor center of rotor 18; P(φ) is the permeance or the reciprocal of the air gap between the stator 12 and the rotor poles 22 as a function of the angle φ between the position vectors characterizing the rotation and rotor poles 22; C_(sj) and C_(ri) are the position vectors of the j^(th) stator pole 14 and the i^(th) rotor poles 22 respectively; φ_(ij) is the angle between C_(sj) and C_(ri) ; and R is the radius of the rotor 18. P(φ) can be determined by using numerical computation or experimentally for a given design.

In order to obtain an optimal solution to the inverse torque model, the torque equation is presented in quadratic form. Further, for clarity in illustrating the inverse torque model, only current sources are used and the mmf's of the pole coils are treated as system input variables. Finally, in practice, it is desirable to have no wiring in the moving parts, and thus the rotor poles 22 comprise only simple iron cores with no excitation coils. With the foregoing parameters, the torque equation can be written in matrix form as follows: ##EQU10##

As indicated in flowchart blocks 284-302, the motor control algorithm 200 determines the optimal electrical current inputs for the n stator coils in order to generate the required actuating torque T with the least amount of energy possible given certain practical operating constraints. In essence, the methodology described hereafter in regard to flowchart blocks 284-302 is an optimization algorithm.

As indicated in flowchart block 284, the vector U=(U₁ U₂ . . . U_(n)), called herein the "optimal principle control vector," is determined relative to the torque vector T. The optimal principle control vector U is an array which comprises a current value U_(i), i=1, . . . ,n, for each of the n stator coils 14 situated about the periphery of the spherical stator 12.

For a specified torque Tε , a control input Uε ^(n) is determined which satisfies the constraint

    T.sub.I =1/2U.sup.T A.sub.I U (A.sub.I.sup.T =A.sub.I)

where I=1, 2, 3 and where the notation ()^(T) denotes the transpose of the vector or the matrix (), and which simultaneously minimizes the cost function

    J=1/2U.sup.T U

In the preferred embodiment, the foregoing cost function represents the total amount of energy input to the n stator poles.

For a specified torque T, the control vector U is given by the following equation:

    U=α'u.sub.1 +β'u.sub.2 +γ'u.sub.3         (28)

where α', β', and γ' are time-varying coefficients to be determined according to the three simultaneous torque constraint equations.

By substituting the expression for U into the torque equations, the following equation is derived: ##EQU11##

As indicated in flowchart block 286, the eigenvalues (λ_(i), i=1,2,3) are found by the method described in the Appendix submitted herewith. Note that [B₁ ]=[B₁ ]^(T) and the elements of B₁ have common factors u₁ ^(T) u₂,u₂ ^(T) u₃,u₁ ^(T) u₃ . . . These properties greatly reduce the computation.

Hence, three unknown time-varying coefficients can be solved from the following three equations:

    X.sup.T [B.sub.1 ]x=2T.sub.1                               (29a)

    X.sup.T [B.sub.2 ]x=2T.sub.2                               (29b)

    X.sup.T [B.sub.3 ]x=2T.sub.3                               (29c)

    where

    x=[α',β',γ'].sup.T.

Equations (29a) and (29b) can be decoupled by noting that

    [B.sub.1 ]v.sub.j =ω.sub.j B.sub.2 v.sub.j           (30)

can be solved for the eigenvalues ω_(j) and the corresponding normal eigenvectors v_(j) (j=1,2,3) which form

    Γ=[v.sub.1 v.sub.2 v.sub.3 ]

    such that

    Γ.sup.T [B.sub.1 ]Γ=I

    and Γ.sup.T [B.sub.2 ]Γ=diag[ω.sub.1,ω.sub.2,ω.sub.3 ]

where the ω_(j) (j=1,2,3) are arranged such that ω₁ ≦ω₂ ≦ω₃.

Thus, by means of the following linear transformation

    X=Γy

where y=[α,β,γ]^(T). Equations (29a)-(29c) become ##EQU12## and i,j=1,2,3. By substituting α,β,γ, Equations (31a)-(31c) become

    α.sup.2 +β.sup.2 +γ.sup.2 =2T.sub.1       (32a)

    ω.sub.1 α.sup.2 +ω.sub.2 β.sup.2 +ω.sub.3 γ.sup.2 =2T.sub.2                                   (32b)

    q.sub.11 α.sup.2 +q.sub.22 β.sup.2 +q.sub.33 γ.sup.2 +2q.sub.12 αβ+2q.sub.13 αγ+2q.sub.23 βγ=2T.sub.3                                    (32c)

Provided that not all the eigenvalues ω_(j) are equal, Equations (32a) and (32b) can be written as ##EQU13##

Substituting for α and β in Equations (33) and (34) respectively, and let γ² =z, a quartic equation of the form

    az.sup.4 +bz.sup.3 +cz.sup.2 +dz+e=0                       (35)

can be obtained. As indicated in flowchart block 288, the foregoing quartic equation (35) is now solved. The coefficients of the quartic equation (35) are algebraic functions of q_(ij) and b_(k) (i,j=1,2,3; k=1,2,3,4). The quartic equation (35) is solved for any real non-negative z within ##EQU14##

Next, as indicated in flowchart block 292, the three time-varying coefficients α', β', and λ' are determined by working backwards such that

    γ→α,β→α',β',γ'

There are several possible solutions for α', β', γ'. A set of solutions is selected such that

    minJ=min1/2∥U∥.sub.2 =min1/2∥α'u.sub.1 +β'u.sub.2 +γ'u.sub.3 ∥               (36)

namely, ##EQU15##

As indicated in the flowchart block 294 the three optimal principal control vector components u₁, u₂, and u₃ are inserted into the equation (28) in order to derive the control vector U. The control vector U is an array which comprises a current value U for each of the n stator coils 14.

Next, at a flowchart block 296, the current values U_(i), where i=1, . . . ,n, for each of the n stator coils 14 are compared with a maximum allowable current level I_(max). If a computed current value U_(i) is greater than the maximum allowable current value I_(max) for a particular stator coil 14, then the computed current value U_(i) is replaced with the maximum allowable current value I_(max), as indicated in a flowchart block 298. Finally, as shown in a flowchart block 302, the current values U_(i), for i=1, . . . ,n, are fed to the n DACs 198 (FIG. 6) by way of the decoder 194 (FIG. 6).

It should be noted that the foregoing novel methodology involving the determination of torques and minimization of a cost function J(U) is equally applicable in other embodiments of a spherical motor which utilize a different rotor actuation means, i.e., an actuation means other than the electromagnetic actuation means utilizing stator and rotor poles 14, 22. Examples of other types of actuation means include pneumatic, hydraulic, or electrostatic systems.

Finally, it will be obvious to those skilled in the art that many other variations may be made to the preferred embodiments described above without departing from the novel teachings and principles of the present invention. All such variations are intended to be incorporated herein and within the scope of the present invention.

APPENDIX GENERATION OF THE THREE OPTIMAL PRINCIPLE CONTROL VECTORS Problem Statement

For a specified torque TεR, find a control input uεR^(m) which satisfies the constraint

    T.sub.I =1/2u.sup.T A.sub.I u (A.sub.I.sup.T =A.sub.I)

and simultaneously minimizes the following cost function, which is energy in the present case:

    J=1/2u.sup.T u

Theorem

Let u* be the optimal solution of the above problem. then ##EQU16## μ(·) is a unit step function, λ_(max) (A) and λ_(min) (A) are the maximum and minimum eigenvalues of A respectively; and u* is the Normalized eigenvector of the following eigenvalue problem

    A u*=λ*(A)u* ∥u∥=1

Accordingly, the minimized cost is ##EQU17##

Proof

By the Rayleigh's theorem

    λ.sub.min (A)∥u∥.sup.2 ≦u.sup.T A u≦λ.sub.max (A)∥u∥.sup.2

we have, for a given torque T

    λ.sub.min (A)∥u∥.sup.2 ≦2T≦λmax (A)∥u∥.sup.2

(1). If T>0, then λ_(max) >0. Since if λ_(max) ≦0, then A≦0 (negative semidefinite), for uεR^(m).ps

    T=1/2u.sup.T A u≦0

This is contradictory to the assumption T>0. Therefore, λ_(max) >0. From the right hand inequality of the Rayleigh's theorem ##EQU18##

(2). If T<0, then λ_(min) <0. Because if λ_(min) ≧0, then A≧0 (positive semidefinite), for uε ^(m),

    T=1/2u.sup.T A u≦0

This conflicts with the assumption T<0. Therefore, λ_(min) 0. From the left hand inequality of the Raleigh's theorem ##EQU19## In the cases of (1) and (2), u* is chosen as ##EQU20## where u* is the normalized eigenvector of the eigenvalue problem

    A u*=λ*(A)u*

λ* is either the λ_(max) or the λ_(min). It can be proven by premultiplying (u*)^(T) ##EQU21## By applying the theorem we just proved on

    T.sub.I =1/2u.sup.T A.sub.I u (I=1,2,3)

respectively, we obtain three optimal control vectors u₁, u₂, u₃. They are the principle control vectors which minimize the control input energy and satisfy each torque constraint in x, y, and z directions. 

Wherefore, the following is claimed;
 1. An orientation sensing system for permitting non-contact three dimensional orientation measurement of a spherical body, comprising:a grid pattern of lines substantially concentric with said spherical body and movable therewith; an image sensor means for retrieving an image of said lines of said grid pattern; and processing means associated with said image sensor, said processing means for determining the three dimensional orientation of said spherical body in a three dimensional reference frame comprising said image sensor based upon said image of said lines.
 2. The system of claim 1, wherein said grid pattern comprises colored lines and said image sensor means is a color sensor.
 3. The system of claim 1, wherein said grid pattern comprises gray lines which vary in shade about said spherical body and said image sensor means is a sensor which detects shades of gray.
 4. The system of claim 1, wherein said grid pattern comprises lines of different widths.
 5. The system of claim 1, further comprising a second image sensor means spaced from said image sensor by ninety degrees about said spherical body, said second image sensor means for retrieving a second image of second lines of said grid pattern, and wherein said processing means determines said spherical body orientation based upon the combination of said image and said second image.
 6. A method for permitting non-contact three dimensional orientation measurement of a spherical body, comprising the steps of:moving a grid pattern substantially concentrically with said spherical body; viewing said grid pattern at a sensor location; and determining a spherical body orientation in a three dimensional reference frame comprising said sensor location based upon said viewing of said grid pattern.
 7. The method of claim 6, further comprising the step of sensing different color lines in said grid pattern.
 8. The method of claim 6, further comprising the step of sensing varying shades of gray in said grid pattern.
 9. The method of claim 6, further comprising the step of sensing different line widths in said grid pattern.
 10. A system for contactless determination of a three dimensional location of a position on a spherical body, comprising:the spherical body; a grid pattern substantially concentric with said spherical body and movable therewith, said grid pattern having first lines converging toward a point and having second lines which are generally parallel and which are generally orthogonal to said first lines; an image sensing means for retrieving an image of two intersecting points established by a first line and two second lines; and processing means for determining the position of said point in three dimensional space based upon said image.
 11. The system of claim 10, further comprising:means for determining first and second displacements respectively between said image sensing means and first and second intersecting points where said first line intersects with said two second lines; means for determining a spin angle of said spherical body based upon a distinguishing feature of said first line and a third displacement between said image sensing means and said first line, said spin angle being the angular displacement of said spherical body about said point from a reference first line of said grid pattern; and means for determining said position of said point based upon said first and second displacements and said spin angle.
 12. The system of claim 10, wherein said spherical body is a rotor and further comprising:a spherical stator surrounding said rotor and having a stator opening; a shaft protruding from said rotor through said stator opening and being disposed in line with said point so that said processing means thereby determines the position of said shaft.
 13. The system of claim 10, wherein said spherical body is a stator having a stator opening and further comprising:a spherical rotor within said stator; and a shaft protruding from said rotor through said stator opening and being disposed in line with said point so that said processing means determines the position of said shaft.
 14. The system of claim 11, wherein said distinguishing feature of said first line is the particular coloring of said first line.
 15. The system of claim 11, wherein said distinguishing feature of said first line is the particular gray shade of said first line.
 16. The system of claim 11, wherein said distinguishing feature of said first line is the particular width of said first line.
 17. A system for contactless determination of a three dimensional location of a position on a spherical body, comprising:the spherical body having the position, said spherical body being fixed in a three dimensional movable coordinate frame; a grid pattern substantially concentric with said spherical body and movable therewith, said grid pattern being fixed in said movable coordinate frame; an image sensing means for retrieving an image of said grid pattern, said image sensing means being fixed in a three dimensional reference coordinate frame; and processing means associated with said image sensing means, said processing means for determining a two dimensional location of said position from said image, said processing means for determining an amount of angular rotation about said position from said image, said processing means for determining a relationship between said movable coordinate frame and said reference coordinate frame based upon said two dimensional location of said position and said amount of angular rotation about said position.
 18. The system of claim 17, further comprising a means for determining a three dimensional location of said position in said reference coordinate frame based upon said relationship between said movable coordinate frame and said reference coordinate frame.
 19. The system of claim 18, further comprising:first lines on said grid pattern converging toward said position; second lines which are generally parallel and which are substantially orthogonal to said first lines, each of said first lines being uniquely distinguishable; wherein said image comprises first and second intersecting points where said first line intersects with two second lines; means for determining first and second displacements respectively between said image sensing means and first and second intersecting points; means for determining said amount of angular rotation based upon a distinguishing feature of said first line and a third displacement between said image sensing means and said first line; and means for determining the location of said position based upon said first and second displacements and said amount of angular rotation.
 20. The system of claim 18, wherein said spherical body is a rotor and further comprising:a spherical stator surrounding said rotor and having a stator opening; a shaft protruding from said rotor through said stator opening and being disposed in line with said point so that said processing means thereby determines a location of said shaft.
 21. The system of claim 18, wherein said spherical body is a stator having a stator opening and further comprising:a spherical rotor within said stator; and a shaft protruding from said rotor through said stator opening and being disposed in line with said position so that said processing means determines a location of said shaft.
 22. A method for contactless determination of a three dimensional location of a position on a spherical body, comprising the steps of:moving a grid pattern substantially concentrically with said spherical body, said grid pattern having first lines converging toward a point and having substantially parallel second lines which are substantially orthogonal to said first lines; retrieving an image of a first line and at least two second lines which intersect said first line; and determining the position of said point in three dimensional space based upon said image.
 23. The method of claim 22, further comprising the steps of:determining locations of intersecting points where said first line intersects with said two second lines; determining an angular displacement of said spherical body about said point from a reference first line of said grid pattern based upon a distinguishing feature of said first line; and determining said position of said point based upon said locations of said intersecting points and said angular displacement.
 24. The method of claim 22, further comprising the step of:retrieving a second image of another first line and another set of second lines; and determining the position of said point based upon both said image and said second image.
 25. The method of claim 22, further comprising the step of determining the position of said point based upon images spaced angularly about said point by ninety degrees.
 26. A method for contactless determination of a three dimensional location of a position on a spherical body, comprising the steps of:providing a grid pattern substantially concentric with the spherical body and movable therewith, said grid pattern and the spherical body being situated in a three dimensional movable coordinate frame; retrieving an image of said grid pattern, said image being fixed in a three dimensional reference coordinate frame; determining a two dimensional location of said position from said image; determining an amount of angular rotation about said position from said image; and determining a relationship between said movable coordinate frame and said reference coordinate frame based upon said two dimensional location of said position and said amount of angular rotation about said position. 